package com.hudsonmq.spring.impl.produce;

import com.hudson.codec.domain.Message;
import com.hudson.common.domain.Duration;
import com.hudson.core.concurrent.CallBack;
import com.hudsonmq.spring.domain.produce.TopicQueueInfo;

public interface RemoteClient {

    Boolean send(Message message, CallBack callBack);

    Boolean relaySend(Message message, CallBack callBack, Duration duration);

    default boolean retrySend(long messageId, TopicQueueInfo topicQueue, Message message, CallBack callBack, int retryNum) {
        return true;
    }
}
